package com.wt.admin.mapper.language;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.wt.admin.domain.dto.language.SentenceDTO;
import com.wt.admin.domain.entity.language.SentenceEntity;
import com.wt.admin.domain.vo.language.ClassificationVO;
import com.wt.admin.domain.vo.language.SentenceVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface SentenceMapper extends BaseMapper<SentenceEntity> {

    IPage<SentenceVO> findAll(Page<SentenceDTO> page, @Param("data") SentenceDTO data);

    List<SentenceEntity> findByClassId(@Param("data") ClassificationVO classificationVO);

    List<SentenceVO> findByClassIds(@Param("list") List<Integer> id);

    void updateBatch(@Param("list") List<SentenceVO> list);
}
